
/**
 * First we will load all of this project's JavaScript dependencies which
 * includes Vue and other libraries. It is a great starting point when
 * building robust, powerful web applications using Vue and Laravel.
 */

require('./bootstrap');

import App from './App.vue'
// //添加mockjs拦截请求，模拟返回服务器数据
// import mock from './api/mock'

//引入elementui
import ElementUI from 'element-ui'
import 'element-ui/lib/theme-default/index.css'
Vue.use(ElementUI)

// 图标
import 'font-awesome/css/font-awesome.min.css'

// vuex
import store from './store'

// vue-router
import VueRouter from 'vue-router'
import routes from './routes'

Vue.use(VueRouter);
//实例化路由组件
const router = new VueRouter({
  // mode: 'history',
  routes
})

// 接口
import api from './api'
window.api=api;
// 创建根实例
new Vue({
  //el: '#app',
  //template: '<App/>',
  router,
  store,
  //components: { App }
  render: h => h(App)
}).$mount('#app')
